#
#	Makefile for dcmsr/libcmr
#

@SET_MAKE@

SHELL = /bin/sh
VPATH = @srcdir@:@top_srcdir@/include:@top_srcdir@/@configdir@/include
srcdir = @srcdir@
top_srcdir = @top_srcdir@
configdir = @top_srcdir@/@configdir@

include $(configdir)/@common_makefile@

ofstddir = $(top_srcdir)/../ofstd
oflogdir = $(top_srcdir)/../oflog
dcmdatadir = $(top_srcdir)/../dcmdata
dcmsr = $(top_srcdir)/../dcmsr

LOCALINCLUDES = -I$(ofstddir)/include -I$(oflogdir)/include -I$(dcmdatadir)/include \
	-I$(dcmsr)/include
LOCALDEFS =

objs = init.o logger.o srnumvl.o tid1001.o tid1204.o tid1411.o tid1500.o tid1600.o \
	cid11.o cid29.o cid29e.o cid42.o cid100.o cid244.o cid244e.o cid4020.o \
	cid4021.o cid4031.o cid4031e.o cid5000.o cid5001.o cid6147.o cid7021.o \
	cid7181.o cid7445.o cid7452.o cid7453.o cid7464.o cid7469.o cid10013.o \
	cid10013e.o cid10033.o cid10033e.o
library = libcmr.$(LIBEXT)


all: $(library)

install: $(library)
	$(configdir)/mkinstalldirs $(DESTDIR)$(libdir)
	$(INSTALL_DATA) $(library) $(DESTDIR)$(libdir)/$(library)
	$(RANLIB) $(DESTDIR)$(libdir)/$(library)


$(library): $(objs)
	$(AR) $(ARFLAGS) $@ $(objs)
	$(RANLIB) $@


clean:
	rm -f $(objs) $(library) $(TRASH)

distclean:
	rm -f $(objs) $(library) $(DISTTRASH)


dependencies:
	$(CXX) -MM $(defines) $(includes) $(CPPFLAGS) $(CXXFLAGS) *.cc  > $(DEP)

include $(DEP)
